package main

import (
	"net"
	"fmt"
)

func main()  {
	tcpaddr,_:=net.ResolveTCPAddr("tcp","10.0.154.198:7527")
	tcpconn,_:=net.DialTCP("tcp",nil,tcpaddr)
	defer tcpconn.Close()
	for{
		line:=""
		fmt.Scanln(&line)
		tcpconn.Write([]byte(line))
		if line =="over"{
			fmt.Println("客户端结束")
			break
		}
		bs:=make([]byte,512)
		n,_:=tcpconn.Read(bs)
		fmt.Println("服务器说：",string(bs[:n]))
	}

}
